ORBSGame.Txt ORBS Standard 1.0 1994 APR 03 Sun David Croft, CompuServe [76600,102] Introduction ------------ This describes the standard file format for an ORBS computer game. ORBS stands for Optional Reality-Bases System. A game is based on the premise that there is a virtual space in which elements exist and interact. The game may be played locally at the console or remotely via modem. Space Files ----------- Each location in space contains an element. An element fills one character space. There is a set maximum number of standard elements. Elements with a value above this maximum are unique entities such as players or unique monsters/hazards. Values are non-negative/unsigned/natural numbers. Not all values in the standard element range need be used. Multiple values for the same element may be used. For example, a value of 0 (NUL) or 32 (SPACE) may be used to indicate empty space. The bit-length of an element is determined by the particular game. The element at any point in space is stored in a space file. A space file is two-dimensional. Three-dimensional space is created by layering space files. Space files are square and in the X and Y direction. All space files for a particular game have the same length on a side. Missing space files are assumed to be filled with elements of 0. Space file filenames are in the format XhhYhhZhh.SPA where "hh" is a hexadecimal signed byte (-128 to 127 = 81h to 7Fh) indicating the distance in "side lengths" from the origin. North | XFFY00Z00.SPA | X00Y00Z00.SPA ( -1, 0, 0) | ( 0, 0, 0) | West - - - - - - - + - - - - - - - East | XFFYFFZ00.SPA | X00YFFZ00.SPA ( -1, -1, 0) | ( 0, -1, 0) | South Elements within a space file are numbered from one to the number of elements on a side squared with one at the top-left and the last at the bottom right. For example, North 1 2 3 4 West 5 6 7 8 East 9 10 11 12 13 14 15 16. South State Files ----------- Each element has a state. State files track their corresponding elements in the space files. The bit-length of a state is determined by the particular game. Missing space files are assumed to be filled with states of 0. State file filenames are similar to those of space files with the exception that the extension is .STA instead of .SPA. Standard Element File --------------------- This a text file with standard element names and character representations in color-@-code text (' ' to '~') and color-@-code decimal ASCII (0 to 255). The color-@-codes table is found on the back cover of the Wildcat! BBS SysOp guide and is presented below. The color-@-codes default to normal black-and-white text when the player's video cannot handle color or blinking text. For other graphical representations such as RIP icons, see Graphics Files. Commas separate/delimit element names and character codes. Quotes may be used to include commas in names and codes. White space (tabs, spaces, etc.) is ignored. Each line, starting with line 0, corresponds to the value of a standard element as used in the space files. This file is read only. The filename is STANDARD.ELE. For an example, @ Color Codes The color codes system follows the format @bf@ where B is the background color and F is the foreground color. Blinking is controlled via background choice. # Background Foreground Color - ---------- ---------- ----- 0 Normal Normal Black 1 Normal Normal Blue 2 Normal Normal Green 3 Normal Normal Cyan (greenish-blue) 4 Normal Normal Red 5 Normal Normal Magenta (reddish-purple) 6 Normal Normal Brown 7 Normal Normal White 8 Blinks FG Hi Intensity Black 9 Blinks FG Hi Intensity Blue A Blinks FG Hi Intensity Green B Blinks FG Hi Intensity Cyan C Blinks FG Hi Intensity Red D Blinks FG Hi Intensity Magenta E Blinks FG Hi Intensity Brown F Blinks FG Hi Intensity White Example file (parenthesized comments would not be in the file): space , "@00@ ", "@00@032" (black space) "forest" , @02@F , "@02@024" (green F/up arrow on black background) mountains , "@06@M" @06@030 (brown M/triangle on black background) sun , "@1C@*", "@1C@7" (hi-int. blinking red */sun on blue) pile of bones (defaults to normal white 'p' on black background) (line 5 is blank indicating that value 5 is not used) Troll,,2 (normal white 'T' or inverse smiley face) "mutant, space" (quotes are used to include comma in element name) Non-Standard Element Files -------------------------- This file describes the additional state information of a non-standard unique entity element. The filename format is hhhhhhhh.ELE where "hhhhhhhh" is unsigned hexadecimal for the value pulled from the space file. Lines 1 to 5 are fixed as described below. Lines 6 and beyond contain state information for the particular non-standard element which may be in any order from moment to moment. The particular state component is determined by its one-word label (underscores are used to make multiple words into one) followed by its value within quotes. Labels are case insensitive (uppercase labels represent the same state component as the word in lower-case). State component labels which are not recognized by the game should be ignored but preserved. Line Example Type Description 1 Dirk Daring string non-standard element name 2 X00Y00Z00 string present space filename location 3 34 positive element position in space file 4 armed warrior string short descriptive label 5 skipped reserved for future use 6 PLAYER "DAVID" string example state component 7 Gold "34" string example state component 8 SCORE "101" string example state component 9 NEXT_MOVE "UP" string example state component 10 SCRIPT "ON" string example state component 11 FACING "357" string example state component 12 ALIGNMENT "NG" string example state component Graphics Files -------------- Each graphic file fills one character space. Filenames are in the format hhhhhhhh.vvv where hhhhhhhh is in hexadecimal ( 00000000 to FFFFFFFF ) and vvv is the graphics method such as RIP. The hexadecimal value corresponds to the value in the space file. Examples: 0000003F.RIP, 0001C94F.RIP. The door determines the user's video standard and transmits the appropriate graphics type icon if available. ORB File -------- The ORB (Optional Reality-Basis) file is composed of plain text lines terminated by a carriage return and line feed. The filename is in the format gamename.ORB. Line Type Description 1 string remark from the author 2 float latest ORBS version for which the game was written 3 positive number of bits per element in the space file 4 positive number of bits per element in the state file 5 positive side length of a state and space file in elements 6 positive number of standard elements